package vip.specimen.system.datasource.validation;

import lombok.Getter;
import lombok.Setter;
import vip.specimen.system.datasource.entity.SystemArticleCategoriesEntity;
import vip.specimen.system.datasource.validation.annotation.CategoriesSuperiorNotSelf;
import vip.specimen.system.datasource.validation.annotation.CategoriesUnique;

import javax.validation.constraints.*;
import java.util.UUID;

/**
 * *@Author: 余浪人
 * *@Date：2021/4/7 15:12
 * *@Email:yulangren520@Gmail.com
 * *@QQ:1368419640
 **/
@Setter
@Getter
public class SystemCategoriesValidation {
    @CategoriesUnique()
    @NotBlank(message = "分类名称不可为空")
    private String categoriesName;
    @Min(value = 0, message = "请输入合法的顺序")
    @Max(value = 9999999, message = "请输入合法的顺序")
    private Integer sequence = 0;
    private String categoriesKeyword;
    @Size(max = 1024, message = "分类描述过长")
    private String categoriesDescription;
    @CategoriesSuperiorNotSelf
    private UUID superior;
}
